package org.colin.dictPojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 用户收藏表
 * </p>
 *
 * @author LiRuiFeng
 * @since 2021-01-25
 */
@TableName("d_user_collection")
public class DUserCollection extends Model<DUserCollection> {

    private static final long serialVersionUID=1L;

    /**
     * 主键
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 类型  1：词头   2：题目
     */
    private Integer type;

    /**
     * 语种
     */
    private Integer language;
    /**
     * 学习等级
     */
    private Integer  level ;

    /**
     * 数据ID
     */
    @TableField("dataId")
    private Integer dataId;

    /**
     * 收藏人
     */
    @TableField("userName")
    private String userName;

    /**
     * 收藏时间
     */
    @TableField("collectionDate")
    private LocalDateTime collectionDate;


    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public Integer getLanguage() {
        return language;
    }

    public void setLanguage(Integer language) {
        this.language = language;
    }

    public Integer getLevel() {
        return level;
    }

    public void setLevel(Integer level) {
        this.level = level;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public Integer getDataId() {
        return dataId;
    }

    public void setDataId(Integer dataId) {
        this.dataId = dataId;
    }

    public LocalDateTime getCollectionDate() {
        return collectionDate;
    }

    public void setCollectionDate(LocalDateTime collectionDate) {
        this.collectionDate = collectionDate;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "DUserCollection{" +
        "id=" + id +
        ", type=" + type +
        ", dataId=" + dataId +
        ", collectionDate=" + collectionDate +
        "}";
    }
}
